Version 3.0 User's Guide |
|
NetCloak Aliases and Caching |
Previous |
Next Contents |
NetCloak supports "aliases" to cloaked files in its configuration file, which resides in the "NetCloak Files" folder and is called "NetCloak.config". A NetCloak alias is a shortcut that you can use in place of the full path to an HTML document. You should not confuse this with Finder aliases, which are unrelated.
Aliases provide several benefits, most important of which are:
The NetCloak.config file in your NetCloak Files folder is a standard text file that you can edit with any text editor or word processor where you must list all of the NetCloak alias names and files that they correspond to. Each line of the file will contain an alias name followed by the path to the file to be served.
All files placed in the NetCloak.config file will be read immediately into RAM when NetCloak starts. If you have frequently accessed pages on your server you may wish to place them in this file whether or not you wish to refer to them by another (aliased) name. The path may be:
For Example, the NetCloak.config file might look like this:
StartPoints.html StartingPoints.html RelativePath.html :PageFolder:MyPage.html FullPath.html HardDisk:DocFolder:Full.html
Full or relative pathnames may use either colons or slashes to separate folder names.
Alias names may start with slashes, however, a leading slash will have no effect. NetCloak will not allow an alias to a folder, but if you wish, alias names may also include slashes to create the appearance that the files are coming from a particular folder. Links must contain the complete alias name, but any folder names included in the alias name need not actually exist.
There must be at least one space in between the alias name and the document path. Also, it is very important to end the alias name with the file extension used to cloak your files. If this extension is not included, the server will not use NetCloak to process the pages and will return a "File not found" error to the user.
To browse or link to an aliased document, simply reference the alias name as if it were in the root folder. For example, the "FullPath.html" file above would be linked by the URL:
"http://your.server.com/FullPath.html"
As stated above, aliased documents are loaded into RAM when NetCloak is started. If you add or change a NetCloak aliased document, you must have NetCloak reload all the aliased documents. One way to do this is to quit NetCloak and restart, but additional methods are provided:
http://your.server.com/NetCloak.acgi$RELOAD
http://your.server.com/RELOAD.nclk
In addition to caching files via NetCloak aliases, NetCloak includes an intelligent dynamic file caching feature. Dynamic caching must be enabled using the Configuration dialog in the NetCloak ACGI. When enabled, NetCloak will cache the 100 most-requested files which fit into the available RAM. These 100 files are in addition to the files aliased (and cached) by the NetCloak.config file. Note, however, that NetCloak will only cache HTML files that it processes, not images or other files.
NetCloak's dynamic cache checks the last modified date of cached files every time the file is served. Thus, when a cached file is modified, the new version will be automatically re-cached the next time it is accessed, without flushing other cached files. This is in contrast to the way WebSTAR's Data Cache plug-in operates, which requires you to flush the entire cache to get newer versions of any modified files. The downside to operating this way is that a small performance penalty is assessed each time a cached files is served.
Copyright © 1996-1999 Maxum Development Corporation http://www.maxum.com/ |
Previous |
Next Contents |